package org.example.controller;

import org.apache.ibatis.annotations.Param;
import org.example.domain.ExcelRecord;
import org.example.service.impl.ExcelRecordServiceImpl;
import org.example.untils.Result;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("excelRecord")
public class ExcelRecordController {

    @Autowired
    private ExcelRecordServiceImpl excelRecordServiceImpl;

    @GetMapping("/getExcelRecordsByOrderNumber")
    public Result getExcelRecordsByOrderNumber(@Param("orderNumber") Integer orderNumber){//获取指定次序的导出记录
        ExcelRecord[] excelRecords= excelRecordServiceImpl.getExcelRecordsByOrderNumber(orderNumber);
        return new Result(200,"获取成功",excelRecords);
    }

}
